from libs.exception import BaseHTTPException
from flask_babel import gettext as _

class HProdBrandParamError(BaseHTTPException):
    error_code = "brand_param_error"
    code = 400
    def __init__(self,message:str|None):
        message = message or ""
        self.description = _("Product Brand parameter error.{message}").format(message=message)
        super().__init__(self.description)

class HProdBrandNotFoundError(BaseHTTPException):
    error_code = "brand_notfound_error"
    code = 400
    def __init__(self,brand_id:str|None):
        brand_id = brand_id or ""
        self.description = _("Product brand not found error.{message}").format(message=brand_id)
        super().__init__(self.description)